#!/bin/bash

echo '=================================== Restoring homebrew... ==================================='

echo 'start to brew update'
brew update
echo 'brew update success'

# Get current directory
cd "$(dirname "${BASH_SOURCE[0]}")"
cur_dir=`pwd`

# import brew bundle from Brewfile
cd $cur_dir
brew bundle
cd ..

echo '=================================== Restore homebrew success! ==================================='
